using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._3DAnalystTools
{
    /// <summary>
    /// <para>TIN Polygon Volume</para>
    /// <para>Calculates the volumetric and surface area between polygons of an input feature class and a TIN surface.</para>
    /// <para>计算输入要素类的面与 TIN 表面之间的体积面积和表面积。</para>
    /// </summary>    
    [DisplayName("TIN Polygon Volume")]
    public class TinPolygonVolume : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public TinPolygonVolume()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_tin">
        /// <para>Input TIN</para>
        /// <para>The input TIN.</para>
        /// <para>输入 TIN.</para>
        /// </param>
        /// <param name="_in_feature_class">
        /// <para>Input Feature Class</para>
        /// <para>The input polygon feature class.</para>
        /// <para>输入面要素类。</para>
        /// </param>
        /// <param name="_in_height_field">
        /// <para>Height Field</para>
        /// <para>The name of the field containing polygon reference plane heights.</para>
        /// <para>包含面参考平面高度的字段的名称。</para>
        /// </param>
        public TinPolygonVolume(object _in_tin, object _in_feature_class, object _in_height_field)
        {
            this._in_tin = _in_tin;
            this._in_feature_class = _in_feature_class;
            this._in_height_field = _in_height_field;
        }
        public override string ToolboxName => "3D Analyst Tools";

        public override string ToolName => "TIN Polygon Volume";

        public override string CallName => "3d.TinPolygonVolume";

        public override List<string> AcceptEnvironments => ["extent", "scratchWorkspace", "workspace"];

        public override object[] ParameterInfo => [_in_tin, _in_feature_class, _in_height_field, _reference_plane.GetGPValue(), _out_volume_field, _surface_area_field, _output_feature_class];

        /// <summary>
        /// <para>Input TIN</para>
        /// <para>The input TIN.</para>
        /// <para>输入 TIN.</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input TIN")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_tin { get; set; }


        /// <summary>
        /// <para>Input Feature Class</para>
        /// <para>The input polygon feature class.</para>
        /// <para>输入面要素类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Feature Class")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_feature_class { get; set; }


        /// <summary>
        /// <para>Height Field</para>
        /// <para>The name of the field containing polygon reference plane heights.</para>
        /// <para>包含面参考平面高度的字段的名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Height Field")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_height_field { get; set; }


        /// <summary>
        /// <para>Reference Plane</para>
        /// <para>The keyword used to indicate whether volume and surface area are calculated ABOVE the reference plane height of the polygons, or BELOW. The default is BELOW.</para>
        /// <para>用于指示体积和表面积是在多边形的参考平面高度上方计算还是在下方计算的关键字。默认值为 BELOW。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Reference Plane")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public _reference_plane_value _reference_plane { get; set; } = _reference_plane_value._BELOW;

        public enum _reference_plane_value
        {
            /// <summary>
            /// <para>ABOVE</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("ABOVE")]
            [GPEnumValue("ABOVE")]
            _ABOVE,

            /// <summary>
            /// <para>BELOW</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("BELOW")]
            [GPEnumValue("BELOW")]
            _BELOW,

        }

        /// <summary>
        /// <para>Volume Field</para>
        /// <para>The name of the output field used to store the volume result. The default is Volume.</para>
        /// <para>用于存储卷结果的输出字段的名称。默认值为 Volume。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Volume Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _out_volume_field { get; set; } = null;


        /// <summary>
        /// <para>Surface Area Field</para>
        /// <para>The name of the output field used to store the surface area result. The default is SArea.</para>
        /// <para>用于存储外围应用结果的输出字段的名称。默认值为 SArea。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Surface Area Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _surface_area_field { get; set; } = null;


        /// <summary>
        /// <para>Output Feature Class</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output Feature Class")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _output_feature_class { get; set; }


        public TinPolygonVolume SetEnv(object extent = null, object scratchWorkspace = null, object workspace = null)
        {
            base.SetEnv(extent: extent, scratchWorkspace: scratchWorkspace, workspace: workspace);
            return this;
        }

    }

}